<?php

use Phinx\Migration\AbstractMigration;

class AddColumnEntityIdInPlanTable extends AbstractMigration
{
    public function up()
    {
        $this->table("plan")
            ->addColumn("entity_id", "integer", [
                "default" => "0",
                "null" => false,
                "limit" => 10,
                "comment" => "集实体id",
                "signed" => false
            ])
            ->save();
    }

    public function down()
    {
        $this->table("plan")
            ->removeColumn("entity_id")
            ->save();
    }
}
